package com.dmgis.qxfw.dataservice.businessservice.api.entity;

/**
 * 功能描述：
 *
 * @auther： zhangyonglong
 * @date：
 * @return：
 * @description
 */
public class Results2 {
    private int code;
    private String msg;
    private int total;
    private Object data;
    private Object data1;
    private Object data2;

    public Results2() {
    }

    public Results2(int code, String msg, int total, Object data, Object data1, Object data2) {
        this.code = code;
        this.msg = msg;
        this.total = total;
        this.data = data;
        this.data1 = data1;
        this.data2 = data2;
    }
    public static Results2 fail(String msg) {

        return new Results2(500,msg,0,null,null,null);
    }

    public static Results2 success(String msg, int total, Object data, Object data1, Object data2) {

        return new Results2(200,msg,total,data,data1,data2);
    }

    /**
     * 获取
     * @return code
     */
    public int getCode() {
        return code;
    }

    /**
     * 设置
     * @param code
     */
    public void setCode(int code) {
        this.code = code;
    }

    /**
     * 获取
     * @return msg
     */
    public String getMsg() {
        return msg;
    }

    /**
     * 设置
     * @param msg
     */
    public void setMsg(String msg) {
        this.msg = msg;
    }

    /**
     * 获取
     * @return total
     */
    public int getTotal() {
        return total;
    }

    /**
     * 设置
     * @param total
     */
    public void setTotal(int total) {
        this.total = total;
    }

    /**
     * 获取
     * @return data
     */
    public Object getData() {
        return data;
    }

    /**
     * 设置
     * @param data
     */
    public void setData(Object data) {
        this.data = data;
    }

    /**
     * 获取
     * @return data1
     */
    public Object getData1() {
        return data1;
    }

    /**
     * 设置
     * @param data1
     */
    public void setData1(Object data1) {
        this.data1 = data1;
    }

    /**
     * 获取
     * @return data2
     */
    public Object getData2() {
        return data2;
    }

    /**
     * 设置
     * @param data2
     */
    public void setData2(Object data2) {
        this.data2 = data2;
    }

    public String toString() {
        return "Results2{code = " + code + ", msg = " + msg + ", total = " + total + ", data = " + data + ", data1 = " + data1 + ", data2 = " + data2 + "}";
    }
}
